Data mirroring is a technique for tolerating failures. By keeping two or more copies of important information, access can continue if one of them is lost or becomes unreachable. Data mirroring can be used inside disk arrays, (commonly referred to as a redundant array of independent disks, or RAID); between disks or disk arrays; and/or across multiple sites (commonly referred to as remote mirroring).
Unfortunately, the design choices for remote mirroring are complicated by competing goals, e.g., keeping the copies as closely synchronized as possible, delaying local (foreground) writes as little as possible, maintaining accessibility in the event of a failure (across as many different failure types as possible), and using as little inter-site network bandwidth (which typically is fairly expensive) as possible.
The most common trade-off is between good performance at low cost against the amount of potential data loss, especially for recently-written data. Simple solutions, such as synchronously updating all copies, can provide good resilience to data loss, but have poor local write performance and incur high network costs in remote-mirroring systems. Accordingly, synchronous mirroring typically is reserved for short-distance mirroring, while asynchronous mirroring is used for long-distance off-site mirroring, especially where the off-site facility is a significant distance away from the operational site. Asynchronous mirroring is particularly preferred where the two facilities are many miles apart, which is often desirable to protect data from the possibility of a large-scale disaster or problem.